home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 2001 May / SGI IRIX Base Documentation 2001 May.iso / usr / share / catman / g_man / cat3 / standard / mmode.z / mmode
Encoding:
Text File  |  1998-10-20  |  6.5 KB  |  146 lines

  1.  
  2.  
  3.  
  4. mmmmmmmmooooddddeeee((((3333GGGG))))                                                            mmmmmmmmooooddddeeee((((3333GGGG))))
  5.  
  6.  
  7.  
  8. NNNNAAAAMMMMEEEE
  9.      mmmmmmmmooooddddeeee      - sets the current matrix mode
  10.  
  11. CCCC SSSSPPPPEEEECCCCIIIIFFFFIIIICCCCAAAATTTTIIIIOOOONNNN
  12.      vvvvooooiiiidddd mmmmmmmmooooddddeeee((((mmmm))))
  13.      sssshhhhoooorrrrtttt mmmm;;;;
  14.  
  15. PPPPAAAARRRRAAAAMMMMEEEETTTTEEEERRRRSSSS
  16.      _m   expects a symbolic constant, one of:
  17.  
  18.          MMMMSSSSIIIINNNNGGGGLLLLEEEE puts the system into single-matrix mode. In single-matrix
  19.          mode, all modeling, viewing, and projection transformations are done
  20.          using a single matrix that combines all these transformations. This
  21.          is the default matrix mode.
  22.  
  23.          MMMMVVVVIIIIEEEEWWWWIIIINNNNGGGG puts the system into multi-matrix mode. In this mode,
  24.          separate ModelView, Projection, and Texture matrices are maintained.
  25.          The ModelView matrix is modified by all matrix operations, except for
  26.          ppppeeeerrrrssssppppeeeeccccttttiiiivvvveeee, oooorrrrtttthhhhoooo, oooorrrrtttthhhhoooo2222, and wwwwiiiinnnnddddoooowwww which always replace the
  27.          current Projection matrix.
  28.  
  29.          MMMMPPPPRRRROOOOJJJJEEEECCCCTTTTIIIIOOOONNNN puts the system into multi-matrix mode. In this mode,
  30.          separate ModelView, Projection, and Texture matrices are maintained.
  31.          The Projection matrix is modified by all matrix operations.
  32.  
  33.          MMMMTTTTEEEEXXXXTTTTUUUURRRREEEE puts the system into multi-matrix mode. In this mode,
  34.          separate ModelView, Projection, and Texture matrices are maintained.
  35.          The Texture matrix is modified by all matrix operations, except for
  36.          ppppeeeerrrrssssppppeeeeccccttttiiiivvvveeee, oooorrrrtttthhhhoooo, oooorrrrtttthhhhoooo2222, and wwwwiiiinnnnddddoooowwww which always replace the
  37.          current Projection matrix.
  38.  
  39. DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  40.      mmmmmmmmooooddddeeee specifies which matrix is the current matrix, and also determines
  41.      whether the system is in single-matrix mode, or in multi-matrix mode.
  42.      The matrix mode and current matrix are determined as follows:
  43.  
  44.                    ____________________________________________
  45.                        mmode      matrix mode   current matrix
  46.                    ____________________________________________
  47.                       MSINGLE       single       only matrix
  48.                      MVIEWING        multi        ModelView
  49.                     MPROJECTION      multi        Projection
  50.                      MTEXTURE        multi         Texture
  51.                    ____________________________________________
  52.                    |||||||
  53.  
  54.  
  55.  
  56.  
  57.  
  58.                                                                |||||||
  59.  
  60.  
  61.  
  62.  
  63.  
  64.  
  65.  
  66.      In single-matrix mode, vertices are transformed directly from object-
  67.      coordinates to clip-coordinates by a single matrix.  All matrix commands
  68.      operate on this, the only matrix.  Single-matrix mode is the default
  69.      mode, but its use is discouraged, because many of the newer GL rendering
  70.      features cannot be used while the system is in single-matrix mode.
  71.  
  72.  
  73.  
  74.  
  75.  
  76.                                                                         PPPPaaaaggggeeee 1111
  77.  
  78.  
  79.  
  80.  
  81.  
  82.  
  83. mmmmmmmmooooddddeeee((((3333GGGG))))                                                            mmmmmmmmooooddddeeee((((3333GGGG))))
  84.  
  85.  
  86.  
  87.      In multi-matrix mode, vertices are transformed from object-coordinates to
  88.      eye-coordinates by the ModelView matrix, then from eye-coordinates to
  89.      clip-coordinates by the Projection matrix.  A third matrix, the Texture
  90.      matrix, is maintained to transform texture coordinates.  While in multi-
  91.      matrix mode, mmodes MMMMVVVVIIIIEEEEWWWWIIIINNNNGGGG, MMMMPPPPRRRROOOOJJJJEEEECCCCTTTTIIIIOOOONNNN, and MMMMTTTTEEEEXXXXTTTTUUUURRRREEEE specify which of
  92.      the three matrices is operated on by matrix modification commands.  Many
  93.      GL rendering operations, including lighting, texture mapping, and user-
  94.      defined clipping planes, require that the matrix mode be multi-matrix.
  95.  
  96.      Both the single matrix that is maintained while mmode is MMMMSSSSIIIINNNNGGGGLLLLEEEE mode,
  97.      and the ModelView matrix that is maintained while not in MMMMSSSSIIIINNNNGGGGLLLLEEEE mode,
  98.      have a stack depth of 32.  The Projection and Texture matrices are not
  99.      stacked.  Thus matrix commands ppppuuuusssshhhhmmmmaaaattttrrrriiiixxxx and ppppooooppppmmmmaaaattttrrrriiiixxxx should not be
  100.      called while the matrix mode is MMMMPPPPRRRROOOOJJJJEEEECCCCTTTTIIIIOOOONNNN or MMMMTTTTEEEEXXXXTTTTUUUURRRREEEE.
  101.  
  102.      Changes between matrix modes MMMMVVVVIIIIEEEEWWWWIIIINNNNGGGG, MMMMPPPPRRRROOOOJJJJEEEECCCCTTTTIIIIOOOONNNN and MMMMTTTTEEEEXXXXTTTTUUUURRRREEEE have no
  103.      effect on the matrix values themselves.  However, when matrix mode
  104.      MMMMSSSSIIIINNNNGGGGLLLLEEEE is entered or left, all matrix stacks are forced to be empty, and
  105.      all matrices are initialized to the identity matrix.
  106.  
  107. SSSSEEEEEEEE AAAALLLLSSSSOOOO
  108.      clipplane, getmmode, lmbind, lookat, ortho, perspective, polarview, rot,
  109.      rotate, scale, texbind, translate, window
  110.  
  111. BBBBUUUUGGGGSSSS
  112.      On IRIS-4D G, GT, GTX systems, and on the Personal IRIS, multi-matrix
  113.      operation is incorrect while mmmmmmmmooooddddeeee is MMMMPPPPRRRROOOOJJJJEEEECCCCTTTTIIIIOOOONNNN.  Specifically,
  114.      vertices are transformed only by the Projection matrix, not by the
  115.      ModelView matrix.
  116.  
  117.  
  118.  
  119.  
  120.  
  121.  
  122.  
  123.  
  124.  
  125.  
  126.  
  127.  
  128.  
  129.  
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136.  
  137.  
  138.  
  139.  
  140.  
  141.  
  142.                                                                         PPPPaaaaggggeeee 2222
  143.  
  144.  
  145.  
  146.